package com.soft.javase.day02.practice.extendsdemo2;

/**
 * @author yzg
 * @desc TODO
 * @date 2025/4/16
 */
public class Father extends GrandFather{
    private String occupation;

    public Father() {
    }

    public Father(String name, int age, String occupation) {
        super(name, age);
        this.occupation = occupation;
    }

    public void getFather(){
        System.out.println("父亲：name=" + this.getName() + ", age=" + this.getAge() + "，职业=" + occupation);
    }
}
